#include <iostream>
#include <string>

#include "subject.h"
#include "observer.h"

using namespace std;

int main()
{
    Boss *boss = new Boss();
    StockObserver *colleague1 = new StockObserver("魏关姹", boss);
    NBAObserver *colleague2 = new NBAObserver("易管查", boss);

    boss->Attach(colleague1);
    boss->Attach(colleague2);
    boss->Detach(colleague1);
    boss->SetState("我胡汉三回来了");
    boss->Notify();

    return 0;
}